package org.deva.erp.common.vo;

import java.io.Serializable;
import java.util.List;

import org.deva.erp.base.entity.IdEntity;
import org.deva.erp.common.entity.Resource;

/**
 * Project: erp<br>
 * Description: 用户登录后，资源对象vo封装<br>
 * Copyright (c) 2012<br>
 * All Rights Reserved.<br>
 * 
 * @author <a href="mailto:gly420@163.com">GuanLuYong</a><br>
 */
public class ResourceVO extends IdEntity implements Serializable {

	private static final long serialVersionUID = 1L;
	private Resource res;
	private Long permission;
	private List<ResourceVO> sons;

	public ResourceVO(Resource res, Long permission) {
		setId(res.getId());
		this.res = res;
		this.permission = permission;
	}

	public ResourceVO() {
	}

	public Resource getRes() {
		return res;
	}

	public void setRes(Resource res) {
		this.res = res;
	}

	public Long getPermission() {
		return permission;
	}

	public void setPermission(Long permission) {
		this.permission = permission;
	}

	public List<ResourceVO> getSons() {
		return sons;
	}

	public void setSons(List<ResourceVO> sons) {
		this.sons = sons;
	}
}
